import { Module } from '@nestjs/common';
import { ConfigModule } from '@nestjs/config';
import { TypeOrmModule } from '@nestjs/typeorm';
import { ThrottlerModule } from '@nestjs/throttler';
import { AuthModule } from './auth/auth.module';
import { UsersModule } from './users/users.module';
import { RolesModule } from './roles/roles.module';
import { PermissionsModule } from './permissions/permissions.module';
import { MenusModule } from './menus/menus.module';
import { PaymentModule } from './payment/payment.module';
import { ReportsModule } from './reports/reports.module';
import { MonitorModule } from './monitor/monitor.module';
import { ScriptsModule } from './scripts/scripts.module';
import { DatabaseModule } from './database/database.module';
import { AnthropicProxyModule } from './anthropic-proxy/anthropic-proxy.module';

@Module({
  imports: [
    ConfigModule.forRoot({
      isGlobal: true,
      envFilePath: '.env',
    }),
    
    ThrottlerModule.forRoot([{
      ttl: 60000,
      limit: 100,
    }]),

    DatabaseModule,

    AuthModule,
    UsersModule,
    RolesModule,
    PermissionsModule,
    MenusModule,
    PaymentModule,
    ReportsModule,
    MonitorModule,
    ScriptsModule,
    AnthropicProxyModule,
  ],
  controllers: [],
  providers: [],
})
export class AppModule {}